<!-- 这是交谈输入框 -->
<script setup>
import { useGptMessageStore,usePromptsStore } from '@/stores/index.js'
const msgStore = useGptMessageStore()
const promptStore = usePromptsStore()
</script>

<template>
  <div>
    <el-input
      class="my-input"
      v-model="msgStore.userMsg"
      type="textarea"
      placeholder="编程问题不懂就问!按回车发送..."
      autosize
      maxlength="80"
      show-word-limit
      resize="none"
      :disabled="promptStore.disabled"
    >
    <template #append>
      发送
    </template>  
  </el-input>
  </div>
</template>

<style lang="less" scoped>
.my-input {
  position: absolute;
  width: 90%;
  bottom: 10px;
}
:deep(.el-textarea__inner) {
  box-sizing: content-box;
  border-radius: 8px;
  padding:10px;
  &:focus {
    // border: 1px solid red;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
  }
}
</style>
